;UoM_1d_if_tsepsyche_ts4x
;TSE-PSYCHE
;Pure Shift Yielded by Chirp Excitation
;Using triple spin echo for suppression of strong coupling artefacts  
;
;Mohammadali Foroozandeh
;University of Manchester
;Avance II+/III Version
;Topspin 3.x and 4.x
; 
;Data can be reconstructed using a macro available at http://nmr.chemistry.manchester.ac.uk
;
;(1)  Foroozandeh, M.; Adams, R. W.; Meharry, N. J.; Jeannerat, D.; Nilsson, M.; Morris, G. A. Angew. Chem. Int. Ed. 2014, 53, 6990.
;(2)  Foroozandeh, M.; Adams, R. W.; Nilsson, M.; Morris, G. A. J. Am. Chem. Soc. 2014, 136, 11867.
;(3)  Foroozandeh, M.; Adams, R. W.; Kiraly, P.; Nilsson, M.; Morris, G. A. Chem. Commun., 2015
;
;$CLASS=HighRes
;$DIM=2D
;$TYPE=
;$SUBTYPE=
;$COMMENT=

#include <Avance.incl>
#include <Delay.incl>
#include <Grad.incl>

;edit for getprosol compatibility
prosol relations=<TSE_PSYCHE>

define delay tauA
define delay tauB

"in0=inf1/2" 
"p2=p1*2"
"tauA=in0/2"
"tauB=dw*2*cnst4"

"cnst50=(cnst20/360)*sqrt((2*cnst21)/(p40/2000000))"
"p30=1000000.0/(cnst50*4)"
"cnst31= (p30/p1) * (p30/p1)"
"spw40=plw1/cnst31" 

"p31=1000000.0/(cnst51*4)"
"cnst32= (p31/p1) * (p31/p1)"
"spw41=plw1/cnst32"
"spw42=spw41"

"p20=p40"
"p21=p41"
"p22=p42"
"acqt0=0"

1 ze
2 d1 pl1:f1
3 p1 ph1
  tauB
  tauA
  50u UNBLKGRAD
  p16:gp1           
  d16
  10u pl0:f1
  d16
  ( center (p41:sp41 ph2):f1 (p21:gp11) )
  d16
  60u
  p16:gp1            
  d16
  tauA
  d0                      
  p16:gp2           
  d16
  10u
  d16 
  ( center (p40:sp40 ph3):f1 (p20:gp10) )
  d16
  10u
  p16:gp2           
  d16  
  p16:gp3           
  d16
  60u
  d16
  ( center (p42:sp42 ph4):f1 (p22:gp12) )
  d16
  10u pl1:f1
  p16:gp3            
  d16
  d0
  50u BLKGRAD                     	
  go=2 ph31

;edit for NUS compatibility
d1 mc #0 to 2 F1QF(caldel(d0,+in0))
  
exit

ph1= 0 0 0 0 0 0 0 0			; Hard_90		
ph2= 0 0 2 2 0 0 2 2			; sweep-180		
ph3= 0 1 0 1 2 3 2 3			; PSYCHE
ph4= 0 0 0 0 0 0 0 0			; sweep-180
ph31=0 2 0 2 0 2 0 2			; Receiver	

;pl0 : zero power
;pl1 : high power
;p1  : 90 degree high power pulse
;p16 : duration of CTP gradients (1m)
;p20 : duration of weak gradient during PSYCHE pulse element
;p21 : duration of weak gradient during 1st 180-degree swept-frequency pulse
;p22 : duration of weak gradient during 2nd 180-degree swept-frequency pulse
;p40 : duration of double-chirp PSYCHE pulse element
;p41 : duration of 1st 180-degree swept-frequency pulse
;p42 : duration of 2nd 180-degree swept-frequency pulse
;d0  : incremented delay
;d1  : relaxation delay
;d16 : recovery delay for gradients
;spw40 : RF power of double-chirp PSYCHE pulse element
;spw41 : RF power of 1st 180-degree swept-frequency pulse
;spw42 : RF power of 2nd 180-degree swept-frequency pulse
;spnam40: file name for PSYCHE pulse element
;spnam41: file name for 1st 180-degree swept-frequency pulse
;spnam42: file name for 2nd 180-degree swept-frequency pulse
;gpz1: CTP gradient (35%)
;gpz2: CTP gradient (49%)
;gpz3: CTP gradient (77%)
;gpz10: weak gradient during PSYCHE element (1-3%)
;gpz11: weak gradient during 1st 180-degree chirp (1-3%)
;gpz12: weak gradient during 2nd 180-degree chirp (1-3%)
;gpnam1: SINE.100
;gpnam2: SINE.100
;gpnam3: SINE.100
;gpnam10: RECT.1
;gpnam11: RECT.1
;gpnam12: RECT.1
;cnst20: desired flip angle for PSYCHE pulse element (degree) (normally 10-25) 
;cnst21: bandwidth of each chirp in PSYCHE pulse element (Hz) (normally 10000)
;cnst51: RF amplitude for 180-degree chirp pulses (Hz)
;in0 : 1/(2 * SW) = DW
;nd0 : 2
;td1 : number of t1 increments
;MC2 : QF